From: Michael Albinus Date: Sun, 11 May 2025 12:25:59 +0000 (+0200) Subject: Improve Tramp test X-Git-Tag: archive/raspbian/1%30.2+1-2+rpi1^2~2^2~24^2~91 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https://%22Program/%22http:/www.example.com/cgi/%22https:/%22Program?a=commitdiff_plain;h=0bf956235e3475f93bd3c146da05a0f87afab714;p=emacs.git Improve Tramp test * test/lisp/net/tramp-tests.el (tramp-test26-interactive-file-name-completion): Adapt test. --- diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el index 2c95cf97ff4..84f864e2d62 100644 --- a/test/lisp/net/tramp-tests.el +++ b/test/lisp/net/tramp-tests.el @@ -5083,6 +5083,14 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." ipv6-postfix tramp-postfix-host-format))) ;; The hop string fits only the initial syntax. (hop (and (eq tramp-syntax orig-syntax) hop)) + ;; Needed for host name completion. + (default-user + (file-remote-p + (concat tramp-prefix-format hop method-string host-string) + 'user)) + (default-user-string + (unless (tramp-string-empty-or-nil-p default-user) + (concat default-user tramp-postfix-user-format))) test result completions) (dolist @@ -5120,7 +5128,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." tramp-prefix-format hop method-string host-string) ,(concat tramp-prefix-format hop method-string - user-string host-string)) + default-user-string host-string)) ,host-string))) ;; Complete user and host name. (unless (or (tramp-string-empty-or-nil-p user)